home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.20031118-20041115 / 000298_fdc@columbia.edu_Tue May 25 10:11:50 2004.msg < prev    next >
Internet Message Format  |  2020-01-01  |  2KB

  1. Path: newsmaster.cc.columbia.edu!not-for-mail
  2. From: Frank da Cruz <fdc@columbia.edu>
  3. Newsgroups: comp.protocols.kermit.misc
  4. Subject: Re: inserting current date into kermit ftp string?
  5. Date: 25 May 2004 14:11:40 GMT
  6. Organization: Columbia University
  7. Lines: 29
  8. Message-ID: <slrncb6l0s.qi0.fdc@sesame.cc.columbia.edu>
  9. References: <369707c7.0405250522.57de029a@posting.google.com>
  10. Reply-To: fdc@columbia.edu
  11. NNTP-Posting-Host: sesame.cc.columbia.edu
  12. X-Trace: newsmaster.cc.columbia.edu 1085494300 13614 128.59.59.56 (25 May 2004 14:11:40 GMT)
  13. X-Complaints-To: postmaster@columbia.edu
  14. NNTP-Posting-Date: 25 May 2004 14:11:40 GMT
  15. User-Agent: slrn/0.9.8.0 (SunOS)
  16. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:15026
  17.  
  18. On 2004-05-25, Matt <mjrosier@bulldog.unca.edu> wrote:
  19. : What's the easiet way to get the year, month and day in numeric format
  20. : and insert it into a specific line of a kermit ftp script?
  21. :
  22. : I have an ftp script I am using in kermit, and the following line is
  23. : date dependent:
  24. :
  25. : ftp cd pub/data/nccf/com/eta/prod/eta.20040520/
  26. :
  27. : eta.20040520 is the part that will change depending on date.
  28. :
  29. For today's date:
  30.  
  31.   ftp cd pub/data/nccf/com/eta/prod/eta.\v(ndate)/
  32.  
  33. \v(ndate) is a built-in variable that is replaced by the current date
  34. in numeric yyyymmdd format.
  35.  
  36. For an arbitrary date...  Well I guess the easiest way is to just
  37. put it in the string:
  38.  
  39.   ftp cd pub/data/nccf/com/eta/prod/eta.20051231/
  40.  
  41. Maybe you didn't say what you really wanted?  Anyway Kermit has everything
  42. you'd want for constructing and manipulating dates; see:
  43.  
  44.   http://www.columbia.edu/kermit/ckermit70.html#x1.6
  45.  
  46. - Frank